package com.godyhm.example.userendport.Protocol;

public class SessionId{
	private short mId;
	public static SessionId INVALID = new SessionId((short)-1);
	public SessionId(short id){
		setId(id);
	}
	public short getId() {
		return mId;
	}
	public void setId(short id) {
		this.mId = id;
	}
	
	public int hashCode() {
		int ret = new Short(mId).hashCode();
		return ret;
	}

	public boolean equals(Object obj) {
		if (null == obj) {
			return false;
		}
		if (!(obj instanceof SessionId)) {
			return false;
		}
		SessionId tmpObj = (SessionId) obj;
		return tmpObj.mId == mId;
	}
}